import axios from 'axios';
//获取指定id的分类详情
let detail = (params) => axios.get('/category/detail', { params });
//获取所有分类
let list = (params) => axios.get('/category/list', { params });
//获取子级分类
let sub = (params) => axios.get('/category/sub', { params });
//编辑指定id分类
let edit = (data) => axios.post('/category/edit', data);
//添加分类
let add = (data) => axios.post('/category/add', data);
//删除指定id分类
let remove = (data) => axios.post('/category/remove', data);
export default {
	list,
	detail,
	edit,
	remove,
	sub,
	add
}
